reduce docker layer size in an attempt to workaround network problems. (#191)
authortsteven4 <tsteven4@users.noreply.github.com>
Mon, 11 Jun 2018 21:55:18 +0000 (15:55 -0600)
committerGitHub <noreply@github.com>
Mon, 11 Jun 2018 21:55:18 +0000 (15:55 -0600)
tools/Dockerfile
tools/make_docker_image [new file with mode: 0755]

index e640100c768251d61f7cbaebd8c5a0ea348b0f33..5a09bb2115f592d2b57139fff265f2cb6a5374b5 100644 (file)
@@ -9,7 +9,12 @@ ARG DEBIAN_FRONTEND=noninteractive
 RUN apt-get update && apt-get install -y --no-install-recommends apt-utils && apt-get install -y apt dpkg libapt-pkg5.0 && apt-get upgrade -y
 
 # install packages needed for gpsbabel build
-RUN apt-get install -y g++ clang make autoconf gperf git expat fop valgrind xsltproc libxml2-utils qt5-default libqt5webkit5-dev qttools5-dev-tools libusb-dev docbook-xml docbook-xsl
+# split into multiple commands to limit layer size
+RUN apt-get install -y g++ make autoconf gperf git valgrind
+RUN apt-get install -y clang
+RUN apt-get install -y expat fop xsltproc libxml2-utils docbook-xml docbook-xsl
+RUN apt-get install -y libusb-dev
+RUN apt-get install -y qt5-default libqt5webkit5-dev qttools5-dev-tools
 
 # install environment for locale test
 RUN apt-get install -y locales && sed -i 's/^# *\(en_US ISO-8859-1\)/\1/' /etc/locale.gen && locale-gen && locale -a
diff --git a/tools/make_docker_image b/tools/make_docker_image
new file mode 100755 (executable)
index 0000000..0559934
--- /dev/null
@@ -0,0 +1,10 @@
+#!/bin/bash -e
+# you must be logged into docker for the push to succeed.
+tag=$(date -u +%Y%m%dT%H%M%SZ)
+docker build -t gpsbabel_build_environment:latest .
+docker tag gpsbabel_build_environment:latest gpsbabel_build_environment:$tag
+docker tag gpsbabel_build_environment:latest tsteven4/gpsbabel_build_environment:latest 
+docker tag gpsbabel_build_environment:latest tsteven4/gpsbabel_build_environment:$tag
+docker push tsteven4/gpsbabel_build_environment:$tag
+docker push tsteven4/gpsbabel_build_environment:latest
+docker image ls